/**************************************************************************
 * @doc CONFIGURATION
 * @module ztconf.h |  
 * Header file for Loading the SoftPay Assist Zontalk configuration parameters
 * into the data files.
 *
 * Product     :   SoftPay 2000 (Global Payment Methodology).
 * <nl>Developer   :   
 * <nl>Notes       :
 *
 * @head3 Zontalk configuration Functions |
 * @index | index_name
 * @end
 *
 * Copyright (c) 1996-2000 by VeriFone Inc. All rights reserved.
 * 
 * No part of this software may be used, stored, compiled, reproduced,
 * modified, transcribed, translated, transmitted, or transferred, in any form 
 * or by any means whether electronic, mechanical, magnetic, optical, 
 * or otherwise, without the express prior written permission of VeriFone, Inc.
 *
 * Revision History
 * ------------------------------------------------------------------------
$Log:  $
 * ------------------------------------------------------------------------
 ********************************************************************************/

#ifndef ZTCONFIG_H
#define ZTCONFIG_H

#include <cfg.h>
#include <define.h>
#include <scalls.h>
#include <transact.h>

#define PARAM_LINES_SIZE 3
#define PARAM_FIELDS_SIZE 24

VS_BOOL fZtConfigReqd (void);
VS_BOOL fZtExprConfReqd (void);
VS_BOOL fResetZtConfigFlag (void);
int inConvFlds (char *szVarName, char *szToBuf, char *szFromBuf, FieldDefinition *psrFldAttrList, int inFldIdx, int inFldSz, VS_BOOL fNewFile);
int inExtractFlds (FieldDefinition  *psrFldAttrList, char *szVarName, unsigned char *szInputBuffer,char *szOutputBuffer, VS_BOOL fNewFile);
VS_BOOL fGetConfigRecs (TRANSACTION_OBJECT *pobTran);
int inSwapBytes (unsigned char *pucByte1, unsigned char *pucByte2);
VS_BOOL fGetHostConfigRecs(int *pinHostFileSize);
VS_BOOL fLoadConfigRecs(char *pszConfigName, int inConfigRecSize, char *pszFldDefName);
int inInitConfigRecs (TRANSACTION_OBJECT *pobTran);

int inGetExprCfg(void);
static int inLdExprCfgVars(CFG_REC *psrCFG, char *szCfgVal);
int inInitExpressConfig (TRANSACTION_OBJECT *pobTran);
VS_BOOL fUpdateTRTRecs(TRANSACTION_OBJECT *pobTran);
VS_BOOL fGetHostConfigSizes(int *pinHostFileSize);

#endif

